<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>出库总览</title>
<script type="text/javascript">
    function outStock() {
        var search_factorys = $("#search_factorys").val();
        var starttime = $("#starttime").val();
        location.href = "/stocks/ajaxbutton?op=outStockInfos&search_factorys="+search_factorys+"&starttime="+starttime;
    }
</script>
<body class="withvernav">
<div class="bodywrapper">
    {{include file='/public/leftmenu.tpl'}}
    <div class="centercontent">
        <div class="pageheader notab">
            <h1 class="pagetitle">出库总览</h1>
            <span class="pagedesc"></span>
        </div>
        <!--pageheader-->
        <div id="contentwrapper" class="contentwrapper">
            <div id="basicform" class="subcontent">
                <!--搜索栏-->
                <form class="stdform stdform2" method="get" id="search" >
                    <div class="tableoptions">
                        出库工厂：
                        <select class="selectCss2" name="search_factorys" id="search_factorys" onChange="searchEmployee()">
                            <option value="">请选择</option>
                            {{foreach from=$factorys item=res key=key}}
                            <option value="{{$res.id}}" {{if $search_factorys eq {{$res.id}}}}selected{{/if}}> {{$res.name}} </option>
                            {{/foreach}}
                        </select>
                        出库时间：
                        <input type="text"  id = "starttime" name="starttime" value="{{$starttime}}" onClick="WdatePicker({dateFmt:'yyyy-MM-dd '})" class="width100 hasDatepicker" />
                        &nbsp;
                        <button type="button" class="btn btn_orange btn_search radius50" onclick="outStock()">查询</button>
                    </div>
                </form>
                <!--搜索栏结束-->
                <table cellpadding="0" cellspacing="0" border="0" class="stdtable">
                    <thead>
                    <tr class="lbbt">
                        <td  bgcolor="#FEFFF1">工厂</td>
                        <td  bgcolor="#FEFFF1">出库数量</td>
                        <td  bgcolor="#FEFFF1">出库时间</td>
                    </tr>
                    </thead>
                    <tbody >
                    {{foreach from=$stocklist item=li key=key}}
                    <tr>
                        <td  bgcolor="#FEFFF1">{{$li.factoryname}}</td>
                        <td  bgcolor="#FEFFF1">{{$li.outsavenum}}</td>
                        <td  bgcolor="#FEFFF1">{{$li.createtime}}</td>
                    </tr>
                    {{/foreach}}
                    </tbody>
                </table>
            </div>
        </div>
</body>
</html>